import request from '/@/utils/request';

/**
 * 文件
 * @param params 要传的参数值
 * @returns 返回接口数据
 * 文件api接口集合
 */
export function useFileApi() {
	return {
		getQATemp: () => {
			return request({
				url: '/product/admin/excel/questionReplyTemplate',
				method: 'get',
				responseType: 'blob',
			});
		},
		getProdTemp: () => {
			return request({
				url: '/product/admin/excel/productTemplate',
				method: 'get',
				responseType: 'blob',
			});
		},
		exportProdByIdList: (data) => {
			return request({
				url: `/product/admin/excel/exportProducts`,
				method: 'post',
				responseType: 'blob',
				data,
			});
		},
	};
}
